package com.cai.seckill.common.vo;

import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * @BelongsProject secKill
 * @Package com.cai.seckill.common.vo
 * @Author Uli1024
 * @CreaterTime 2022/8/4 20:15
 */
@Data
public class LoginVo implements Serializable {
    @NotNull(message = "手机号不能为空")
    @Pattern(regexp = "^(13[0-9]|14[5|7]|15[0|1|2|3|4|5|6|7|8|9]|18[0|1|2|3|5|6|7|8|9])\\d{8}$", message = "手机号码格式不正确")
    private String mobile;

    @NotNull(message = "密码不能为空")
    @Length(min = 32)
    private String password;
}

